void main() {
  // 创建男人对象
  Man man = Man('李雷', 13,['张三','李四']);
  print({man.name,man.friends});
  man.eat();

  // 创建女人对象
  Woman woman = Woman('韩梅梅', 14);
  print(woman.name);
  woman.eat();
}


// 人类
class Person{
  Person(this.name, this.age);

  String? name;
  int? age;

  void eat() {
    print('$name -- eat');
  }
}
/// 男人类
class Man extends Person{
  Man(super.name, super.age,this.friends);
  List? friends;
}

/// 女人类
class Woman extends Person{
  Woman(super.name, super.age);
}